package cn.dc406.labc406mgr.mapper;

import cn.dc406.labc406mgr.entity.User;
import org.apache.ibatis.annotations.Insert;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Select;

import java.util.List;

@Mapper
public interface LoginRegMapper {
    @Select("select * from users where username=#{username} limit 1")
    User selectUserByUsername(String username);

    @Insert("insert into users(username,password,auth) value(#{username},#{password},'0')")
    int insertUser(User user);
}
